#ifndef __CLIENT_THREAD__
#define __CLIENT_THREAD__

#include <windows.h>
#include "Msg\hzCommander.h"
#include "..\Common\CommonNetwork.h"
#include "ClientServiceRequester.h"
#include "ClientObjectManager.h"


class hz::commander;
class client_base;


// recv broadcast data from server.
struct broadcast_thread_arg {
	hz::commander*		PtrCommander;
	object_manager*		PtrObjectManager;
	network*			PtrBroadcastNetwork;
	client_base*		PtrClient;	
};

DWORD WINAPI BroadcastReceiverThread(LPVOID arg);


// object sync
struct motion_update_threade_arg {
	object_manager*		PtrObjectManager;
	network*			PtrUDPNetwork;
};

DWORD WINAPI MotionUpdateThread(LPVOID arg);


// send udp link data to target.
struct udp_link_thread_arg { 
	network*		PtrUDPNetwork;
	unsigned int	MyClientCode;
	string			TargetIP;
	unsigned int	TargetPort;
};

DWORD WINAPI UdpLinkThread(LPVOID arg);


#endif